3.83 \(\int \frac{1+x^2}{1-x^2+x^4} \, dx\)

Optimal. Leaf size=23 \[ \tan ^{-1}\left (2 x+\sqrt{3}\right )-\tan ^{-1}\left (\sqrt{3}-2 x\right ) \]

[Out]

-ArcTan[Sqrt[3] - 2*x] + ArcTan[Sqrt[3] + 2*x]

_______________________________________________________________________________________

Rubi [A]  time = 0.036119, antiderivative size = 23, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 3, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167 \[ \tan ^{-1}\left (2 x+\sqrt{3}\right )-\tan ^{-1}\left (\sqrt{3}-2 x\right ) \]

Antiderivative was successfully verified.

[In]  Int[(1 + x^2)/(1 - x^2 + x^4),x]

[Out]

-ArcTan[Sqrt[3] - 2*x] + ArcTan[Sqrt[3] + 2*x]

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 7.65397, size = 19, normalized size = 0.83 \[ \operatorname{atan}{\left (2 x - \sqrt{3} \right )} + \operatorname{atan}{\left (2 x + \sqrt{3} \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((x**2+1)/(x**4-x**2+1),x)

[Out]

atan(2*x - sqrt(3)) + atan(2*x + sqrt(3))

_______________________________________________________________________________________

Mathematica [A]  time = 0.0107325, size = 12, normalized size = 0.52 \[ -\tan ^{-1}\left (\frac{x}{x^2-1}\right ) \]

Antiderivative was successfully verified.

[In]  Integrate[(1 + x^2)/(1 - x^2 + x^4),x]

[Out]

-ArcTan[x/(-1 + x^2)]

_______________________________________________________________________________________

Maple [A]  time = 0.018, size = 20, normalized size = 0.9 \[ \arctan \left ( 2\,x-\sqrt{3} \right ) +\arctan \left ( 2\,x+\sqrt{3} \right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((x^2+1)/(x^4-x^2+1),x)

[Out]

arctan(2*x-3^(1/2))+arctan(2*x+3^(1/2))

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{x^{2} + 1}{x^{4} - x^{2} + 1}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 + 1)/(x^4 - x^2 + 1),x, algorithm="maxima")

[Out]

integrate((x^2 + 1)/(x^4 - x^2 + 1), x)

_______________________________________________________________________________________

Fricas [A]  time = 0.284387, size = 9, normalized size = 0.39 \[ \arctan \left (x^{3}\right ) + \arctan \left (x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 + 1)/(x^4 - x^2 + 1),x, algorithm="fricas")

[Out]

arctan(x^3) + arctan(x)

_______________________________________________________________________________________

Sympy [A]  time = 0.191684, size = 7, normalized size = 0.3 \[ \operatorname{atan}{\left (x \right )} + \operatorname{atan}{\left (x^{3} \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x**2+1)/(x**4-x**2+1),x)

[Out]

atan(x) + atan(x**3)

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.273567, size = 41, normalized size = 1.78 \[ \frac{1}{4} \, \pi{\rm sign}\left (x\right ) + \frac{1}{2} \, \arctan \left (\frac{x^{4} - 3 \, x^{2} + 1}{2 \,{\left (x^{3} - x\right )}}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 + 1)/(x^4 - x^2 + 1),x, algorithm="giac")

[Out]

1/4*pi*sign(x) + 1/2*arctan(1/2*(x^4 - 3*x^2 + 1)/(x^3 - x))